package com.lee.mq.mqclient;

import java.io.IOException;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: lishuo
 * Date: 2023-10-31
 * Time: 11:41
 */
public class ConnectionFactory {
    // BrokerServer的IP地址
    private String host;
    // BrokerServer的端口号
    private int port;

    public Connection newConnection() throws IOException {
        Connection connection = new Connection(host,port);
        return connection;
    }

    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }
}
